﻿using System;

namespace diantou.dataModel
{
    /// <summary>
    /// 勋章
    /// </summary>
    [fastCSharp.emit.jsonSerialize(IsAllMember = true)]
    [fastCSharp.emit.dataSerialize(IsReferenceMember = false)]
    [fastCSharp.code.cSharp.webView.clientType(Name = "diantou.medal")]
    [fastCSharp.code.cSharp.sqlModel(LogTcpCallService = "DataLog")]
    public partial class medal
    {
        /// <summary>
        /// 勋章标识
        /// </summary>
        [fastCSharp.code.cSharp.webView.outputAjax]
        public int Id;
        /// <summary>
        /// 勋章名称
        /// </summary>
        [fastCSharp.emit.dataMember(PrimaryKeyIndex = 1, MaxStringLength = 32)]
        public string Name;
        /// <summary>
        /// 补充说明
        /// </summary>
        [fastCSharp.emit.dataMember(MaxStringLength = 256)]
        public string Remark = string.Empty;
        /// <summary>
        /// 图片
        /// </summary>
        [fastCSharp.emit.dataMember(IsAscii = true, MaxStringLength = 64)]
        public sqlMember.image Icon = string.Empty;
        /// <summary>
        /// 勋章类型
        /// </summary>
        public enum medalType : byte
        {
            /// <summary>
            /// 问题分组
            /// </summary>
            ProblemGroup,
            /// <summary>
            /// 问题版本
            /// </summary>
            ProblemVersion,
        }
        /// <summary>
        /// 勋章类型
        /// </summary>
        [fastCSharp.emit.dataMember(DataType = typeof(byte))]
        public medalType Type;
        /// <summary>
        /// 问题标识集合
        /// </summary>
        [fastCSharp.emit.dataMember(IsAscii = true, MaxStringLength = 1024)]
        public string ProblemIds;
        /// <summary>
        /// 稀有度
        /// </summary>
        public enum rarityType : byte
        {
            多如牛毛 = 1,
            比比皆是,
            普普通通,
            一枚难求,
            不可多得,
            奇货可居,
            千里挑一,
            寥若晨星,
            百年不遇,
            稀世珍宝,
            凤毛麟角,
            千载难逢,
            盖世无双,
            空前绝后,
        }
        /// <summary>
        /// 稀有度
        /// </summary>
        [fastCSharp.emit.dataMember(DataType = typeof(byte))]
        public rarityType Rarity;
        /// <summary>
        /// 最少通过测试数量
        /// </summary>
        public int AcceptedProblemCount;
    }
}
